<template>
  <div>
    <!-- <index-banner /> -->
    <!-- <index-contenta /> -->
    <index-about />
    <!-- 成功案例 -->
    <div class="case">
      <div class="content1_nav">
        <span class="ll">成功案例</span>
        <span class="rr">
          <NuxtLink to="/case">MORE</NuxtLink>
        </span>
      </div>
      <div class="case_tu">
        <ul>
          <li v-for="item in caseinfo.data.slice(1, 9)" :key="item.id">
            <NuxtLink :to="'/news' + item.id + '.html'">
              <img :src="item.tupian" border="0" width="215" height="196" :alt="item.biaoti" />
            </NuxtLink>
            <p>
              <NuxtLink :to="'/news' + item.id + '.html'">{{ item.biaoti }}</NuxtLink>
            </p>
          </li>
        </ul>
      </div>
    </div>
    <!-- 新闻资讯 -->
    <div class="news">
      <div class="news_content">
        <div class="newss"></div>
        <div class="news1">
          <div class="news1u">ES/<NuxtLink to="/newslist1">公司新闻</NuxtLink>
          </div>
          <div class="news1d">
            <ul>
              <li v-for="item in newsinfo1.data">
                >
                <NuxtLink :to="'/news' + item.id + '.html'">{{ item.biaoti }}</NuxtLink>
              </li>
            </ul>
          </div>
        </div>
        <div class="newsss"></div>
        <div class="news2">
          <div class="newslu2">
            NDUSTRY/<NuxtLink to="/newslist2">行业资讯</NuxtLink>
          </div>
          <div class="news1d">
            <ul>
              <li v-for="item in newsinfo2.data">
                >
                <NuxtLink :to="'/news' + item.id + '.html'">{{ item.biaoti }}</NuxtLink>
              </li>
            </ul>
          </div>
        </div>
        <div class="news3">
          <div class="newslu3">
            PTIMIZAT/<NuxtLink to="/newslist3">软件应用</NuxtLink>
          </div>
          <div class="news1d">
            <ul>
              <li v-for="item in newsinfo3.data">
                >
                <NuxtLink :to="'/news' + item.id + '.html'">{{ item.biaoti }}</NuxtLink>
              </li>
            </ul>
          </div>
        </div>
      </div>
    </div>
    <index-friend />
  </div>
</template>

<script setup lang="ts">
const runtimeConfig = useRuntimeConfig();
const { data: caseinfo }: any = await useFetch(
  runtimeConfig.public.apiBase + "/news?pageSize=10&pageNum=1&lanmu=4"
);
const { data: newsinfo1 }: any = await useFetch(
  runtimeConfig.public.apiBase + "/news?pageSize=10&pageNum=1&lanmu=1"
);
const { data: newsinfo2 }: any = await useFetch(
  runtimeConfig.public.apiBase + "/news?pageSize=10&pageNum=1&lanmu=2"
);
const { data: newsinfo3 }: any = await useFetch(
  runtimeConfig.public.apiBase + "/news?pageSize=10&pageNum=1&lanmu=3"
);

</script>

<style scoped>
.case {
  width: 965px;
  height: 580px;
  border: #c9c9c9 1px solid;
  margin: 15px auto;
}

.case_tu ul {
  margin-top: 15px;
}

.case_tu ul li {
  float: left;
  display: inline;
  margin-left: 13px;
  line-height: 20px;
  text-align: center;
}

.case_tu ul li img {
  border: #cecccc 2px solid;
  padding: 4px;
}

.case_tu ul li a:hover img {
  border: 2px #e13d41 solid;
}

.case_tu ul li p {
  line-height: 40px;
}

.content1_nav {
  background: url(/images/content_nav_bg.jpg) repeat-x top center;
  margin-top: 1px;
  width: 951px;
  height: 33px;
  margin: 0 auto;
  font-size: 14px;
  font-weight: bold;
  line-height: 30px;
  padding-left: 10px;
  color: #555555;
}

.ll {
  float: left;
  background: url(/images/tt.jpg) no-repeat center left;
  padding-left: 15px;
  line-height: 33px;
}

.rr {
  float: right;
  margin-right: 10px;
  background: url(/images/more.jpg) no-repeat right center;
  width: 45px;
  height: 33px;
  font-size: 10px;
  line-height: 33px;
}

.rr a {
  color: #888787;
}

.news {
  width: 965px;
  height: 320px;
  border: #c9c9c9 1px solid;
  margin: 0 auto;
}

.news a {
  color: #000;
  text-decoration: none;
}

.news a:hover {
  color: #900;
  text-decoration: underline;
}

.news_content {
  width: 820px;
  margin: 23px auto;
}

.news1 {
  float: left;
  background: url(/images/content2_bg.jpg) no-repeat right center;
  width: 245px;
  height: 300px;
  display: inline;
}

.news1u {
  background: url(/images/news1u_bg.jpg) no-repeat left center;
  width: 140px;
  height: 30px;
  line-height: 30px;
  padding-left: 40px;
  font-size: 14px;
  font-weight: bold;
}

.newslu2 {
  background: url(/images/news2_bg.jpg) no-repeat left center;
  width: 140px;
  height: 30px;
  line-height: 30px;
  padding-left: 30px;
  font-size: 14px;
  font-weight: bold;
}

.newslu3 {
  background: url(/images/news3_bg.jpg) no-repeat left center;
  width: 140px;
  height: 30px;
  line-height: 30px;
  padding-left: 40px;
  font-size: 14px;
  font-weight: bold;
}

.news1d {
  margin-top: 5px;
}

.news1d {
  margin-left: 15px;
}

.news1d ul li {
  line-height: 25px;
}

.news1d ul li a {
  color: #4e4e4e;
}

.news2 {
  width: 250px;
  height: 300px;
  background: url(/images/content2_bg.jpg) no-repeat right center;
  float: left;
}

.news3 {
  width: 250px;
  float: right;
  height: 300px;
}

.newsss {
  width: 60px;
  float: left;
  height: 300px;
}
</style>